#ifndef MYTCPSERVER_H
#define MYTCPSERVER_H

#include <QObject>
#include <QTcpServer>
class MyThread;
class MyTcpServer : public QTcpServer {
  Q_OBJECT
public:
  explicit MyTcpServer(QObject *parent = nullptr);

signals:
  void sendData(QByteArray data);

protected:
  virtual void incomingConnection(qintptr socketDescriptor); //网络描述符

protected slots:
  void socketDisconnectedSlot(MyThread *th);
};

#endif // MYTCPSERVER_H
